<include file="Public/head" title="个人中心"/>
<include file="Public/back_head"/>
<div class="main">
    <div class="personal_warp">
        <div class="personal_title clear">
            <a href="{:U('user_info')}">
                <div class="person_img" style="background:url({$user.headimgurl}) no-repeat center;background-size:cover;"></div>
                <div class="person_info">
                    <div class="person_name">{$user.nickname}</div>
                    <div class="person_phone"><i class="iconfont icon-shouji"></i>{$user.mobile|default='（尚未认证）'}</div>
                </div>
                <i class="iconfont icon-zuoyoujiantou2 r_c"></i>
            </a>
        </div>
        <div class="person_catgory">
            <ul class="clear">
                <li>
                    <a href="{:U('Order/order_pay')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont1.png)"></i>待付款<if condition="$list.pay neq 0"><span>{$list.pay}</span></if>
                    </a>
                </li>
                <li>
                    <a href="{:U('Order/order_send')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont2.png)"></i>待发货<if condition="$list.hair neq 0"><span>{$list.hair}</span></if>
                    </a>
                </li>
                <li>
                    <a href="{:U('Order/order_confirm')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont3.png)"></i>待收货<if condition="$list.receipt neq 0"><span>{$list.receipt}</span></if>
                    </a>
                </li>
                <li>
                    <a href="{:U('Order/order_complete')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont4.png)"></i>已完成<if condition="$list.complete neq 0"><span>{$list.complete}</span></if>
                    </a>
                </li>
                <li>
                    <a href="{:U('Order/order_refund')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont5.png)"></i>退货退款<if condition="$list.refund neq 0"><span>{$list.refund}</span></if>
                    </a>
                </li>
            </ul>
        </div>
        <div class="person_fl">
            <ul>
                <li class="MarginTop">
                    <a href="{:U('account')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont10.png)"></i>我的账号<i class="iconfont icon-zuoyoujiantou2"></i><span></span>
                    </a></li>
                <li>
                    <a href="{:U('integral_info')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont11.png)"></i>我的积分<i class="iconfont icon-zuoyoujiantou2"></i><span>{$user.have_cent}</span>
                    </a>
                </li>
            </ul>
            <ul>
                <li class="MarginTop">
                    <a href="{:U('Bike/index')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont12.png)"></i>我的车库<i class="iconfont icon-zuoyoujiantou2"></i><span></span>
                    </a>
                </li>
                <li>
                    <a href="{:U('Bike/info')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont13.png)"></i>我的车况<i class="iconfont icon-zuoyoujiantou2"></i><span> </span>
                    </a>
                </li>
            </ul>
            <ul>
                <li class="MarginTop">
                	<a href="{:U('Relay/index')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont18.png)"></i>出让中心<i class="iconfont icon-zuoyoujiantou2"></i><span></span>
                    </a>
                </li>
                <li>
					<if condition="$relay_info eq null">
						<a href="javascript:void(0)" id="relay_bike">
							<i style="background-image: url(__PUBLIC__/home/image/iconfont14.png)"></i>单车接力<i class="iconfont icon-zuoyoujiantou2"></i><span></span>
						</a>
					<else/>
						<a href="{:U('Relay/confirm_relay')}">
							<i style="background-image: url(__PUBLIC__/home/image/iconfont14.png)"></i>单车接力<i class="iconfont icon-zuoyoujiantou2"></i><span></span>
						</a>
					</if>
                </li>
            </ul>
            <ul>
                <li class="MarginTop">
                    <a href="{:U('feedback')}">
                        <i style="background-image: url(__PUBLIC__/home/image/iconfont15.png)"></i>投诉与建议<i class="iconfont icon-zuoyoujiantou2"></i><span></span>
                    </a>
                </li>
            </ul>
        </div>
    </div>
</div>
<include file="Public/jssdk"/>
<script>
wx.ready(function () {
	$('#relay_bike').click(function(){
		wx.scanQRCode({
			needResult: 1, // 默认为0，扫描结果由微信处理，1则直接返回扫描结果，
			scanType: ["qrCode","barCode"], // 可以指定扫二维码还是一维码，默认二者都有
			success: function (res) {
				var result = res.resultStr; // 当needResult 为 1 时，扫码返回的结果
				location.href = result+'&dotype=2';
			}
		});
	})
});
</script>
<include file="Public/foot"/>